<%@ page language="java" import="java.util.*,cn.sypt.yuhao.domain.*" pageEncoding="utf-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/home/";

User ub=(User)session.getAttribute("user");
%>

<!DOCTYPE html>
<html lang="en">
<head>
   
    <meta charset="utf-8">
    <title>重置密码页面</title>
    <base href="<%=basePath%>">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <meta name="description" content="Charisma, a fully featured, responsive, HTML5, Bootstrap admin template.">
    <meta name="author" content="Muhammad Usman">

    <!-- The styles -->
    <link id="bs-css" href="css/bootstrap-cerulean.min.css" rel="stylesheet">

    <link href="css/charisma-app.css" rel="stylesheet">
    <link href='bower_components/fullcalendar/dist/fullcalendar.css' rel='stylesheet'>
    <link href='bower_components/fullcalendar/dist/fullcalendar.print.css' rel='stylesheet' media='print'>
    <link href='bower_components/chosen/chosen.min.css' rel='stylesheet'>
    <link href='bower_components/colorbox/example3/colorbox.css' rel='stylesheet'>
    <link href='bower_components/responsive-tables/responsive-tables.css' rel='stylesheet'>
    <link href='bower_components/bootstrap-tour/build/css/bootstrap-tour.min.css' rel='stylesheet'>
    <link href='css/jquery.noty.css' rel='stylesheet'>
    <link href='css/noty_theme_default.css' rel='stylesheet'>
    <link href='css/elfinder.min.css' rel='stylesheet'>
    <link href='css/elfinder.theme.css' rel='stylesheet'>
    <link href='css/jquery.iphone.toggle.css' rel='stylesheet'>
    <link href='css/uploadify.css' rel='stylesheet'>
    <link href='css/animate.min.css' rel='stylesheet'>

    <!-- jQuery -->
    <script src="bower_components/jquery/jquery.min.js"></script>

    <!-- The HTML5 shim, for IE6-8 support of HTML5 elements -->
    <!--[if lt IE 9]>
    <script src="http://html5shim.googlecode.com/svn/trunk/html5.js"></script>
    <![endif]-->

    <!-- The fav icon -->
    <link rel="shortcut icon" href="img/favicon.ico">
    
    <script language="javascript" src="js/trim.js"></script>
    <script language="javascript">
    
    function checkSub()
      {
      	var flag = false;
      	var ypass =aform.ypass.value;
      	var cpassword = aform.upass.value;
      	var spw = aform.spw.value;
      	//var yemail=bform.yemail.value;
      	
      	var yxyzm =aform.yxyzm.value;
      	
    
      	var zzs=/^[a-z0-9A-Z]{6,15}$/;
      	var zzc=/^\w{1,12}@[a-z0-9]{1,8}\.(com)|( cn)$/;
        if(ypass.trim()=="")
        {
          window.alert("原密码不能为空");
        }
      	else if(cpassword.trim()=="")
      	{
      		window.alert("密码不能为空");
      	}
      	else if(yxyzm.trim()=="")
      	{
      	   window.alert("邮箱验证码不能为空");
      	}
     
      	else if(spw.trim()=="")
      	{
      		window.alert("确认密码不能为空");
      	}
        else if(spw.trim()!=cpassword.trim())
      	{
      		window.alert("两次密码输入不一致");
      	}
      	
        else
      	{
      		flag = true;
			
      	}
      	return flag;
      }

    
    
    </script>

</head>

<body>
    <jsp:include flush="true" page="head.jsp"></jsp:include>
<div class="ch-container">
    <div class="row">
        
   <jsp:include flush="true" page="left.jsp"></jsp:include>

       

        <div id="content" class="col-lg-10 col-sm-10">
            <!-- content starts -->
            <div>
    <ul class="breadcrumb">
        <li>
            <a href="#">个人管理中心</a>
        </li>
        <li>
            <a href="#">密码重置</a>
        </li>
    </ul>
</div>



<div class="row">
    <div class="box col-md-12">
        <div class="box-inner">
        <h3>重置密码第一步</h3>
            <div class="box-header well" data-original-title="">
                <h2><i class="glyphicon glyphicon-edit"></i>获取邮箱验证码</h2>

             
            </div>
            <div class="box-content">
                <form action="/sypt/grglCl?flag=yxyzm" method="post">                  
                    <button type="submit" class="btn btn-default">点击获取邮箱验证码</button><br>
                                                                                                       
                </form>

            </div>
        </div>
    </div>
    <!--/span-->

</div><!--/row-->

<h3>重置密码第二步</h3>
<br>
<div class="row">
        <div class="well col-md-5 center login-box">
            <div class="alert alert-info">
                请按要求填写下列信息
            </div>
            <form class="form-horizontal" action="/sypt/grglCl?flag=czmm" name="aform" method="post">
                <fieldset>
                    <div class="input-group input-group-lg">
                        <span class="input-group-addon"></span>
                        <input type="text" class="form-control" name="ypass" placeholder="原密码"/>
                    </div>
                    <div class="clearfix"></div><br>

                    <div class="input-group input-group-lg">
                        <span class="input-group-addon"></span>
                        <input type="password" class="form-control" name="upass" placeholder="新密码" />
                    </div>
                    <div class="clearfix"></div><br>
                    <div class="input-group input-group-lg">
                        <span class="input-group-addon"></span>
                        <input type="password" class="form-control" name="spw" placeholder="确认新密码" />
                    </div>
                    <div class="clearfix"></div><br>
                    <div class="input-group input-group-lg">
                        <span class="input-group-addon"></span>
                        <input type="text" class="form-control" name="yxyzm" placeholder="邮箱验证码" />
                    </div>

                    
                    <div class="clearfix"></div>
                    <button type="submit" onclick="return checkSub();" class="btn btn-primary">提交</button>

                   
                </fieldset>
            </form>
        </div>
        <!--/span-->
    </div><!--/row-->


  

<!-- chart libraries start -->
<script src="bower_components/flot/excanvas.min.js"></script>
<script src="bower_components/flot/jquery.flot.js"></script>
<script src="bower_components/flot/jquery.flot.pie.js"></script>
<script src="bower_components/flot/jquery.flot.stack.js"></script>
<script src="bower_components/flot/jquery.flot.resize.js"></script>
<!-- chart libraries end -->
<script src="js/init-chart.js"></script>

    <!-- content ends -->
    </div><!--/#content.col-md-0-->
</div><!--/fluid-row-->

   

    <hr>

   

  <jsp:include flush="true" page="foot.jsp"></jsp:include>

</div><!--/.fluid-container-->

<!-- external javascript -->

<script src="bower_components/bootstrap/dist/js/bootstrap.min.js"></script>

<!-- library for cookie management -->
<script src="js/jquery.cookie.js"></script>
<!-- calender plugin -->
<script src='bower_components/moment/min/moment.min.js'></script>
<script src='bower_components/fullcalendar/dist/fullcalendar.min.js'></script>
<!-- data table plugin -->
<script src='js/jquery.dataTables.min.js'></script>

<!-- select or dropdown enhancer -->
<script src="bower_components/chosen/chosen.jquery.min.js"></script>
<!-- plugin for gallery image view -->
<script src="bower_components/colorbox/jquery.colorbox-min.js"></script>
<!-- notification plugin -->
<script src="js/jquery.noty.js"></script>
<!-- library for making tables responsive -->
<script src="bower_components/responsive-tables/responsive-tables.js"></script>
<!-- tour plugin -->
<script src="bower_components/bootstrap-tour/build/js/bootstrap-tour.min.js"></script>
<!-- star rating plugin -->
<script src="js/jquery.raty.min.js"></script>
<!-- for iOS style toggle switch -->
<script src="js/jquery.iphone.toggle.js"></script>
<!-- autogrowing textarea plugin -->
<script src="js/jquery.autogrow-textarea.js"></script>
<!-- multiple file upload plugin -->
<script src="js/jquery.uploadify-3.1.min.js"></script>
<!-- history.js for cross-browser state change on ajax -->
<script src="js/jquery.history.js"></script>
<!-- application script for Charisma demo -->
<script src="js/charisma.js"></script>


</body>

  <script>
   <% 
     String msg=(String)request.getAttribute("msg");
     if(msg!=null)
     {
   %>
     alert('<%=msg%>');
   <%     
     }
   %>
</script>
</html>
